{% if site.disqus %}
    <section class="post-footer-item comment">
      <div id="disqus_thread"></div>
    </section>

    <script>
      /**
       *  RECOMMENDED CONFIGURATION VARIABLES: EDIT AND UNCOMMENT THE SECTION BELOW TO INSERT DYNAMIC VALUES FROM YOUR PLATFORM OR CMS.
       *  LEARN WHY DEFINING THESE VARIABLES IS IMPORTANT: https://disqus.com/admin/universalcode/#configuration-variables*/
      /*
      var disqus_config = function () {
      this.page.url = PAGE_URL;  // Replace PAGE_URL with your page's canonical URL variable
      this.page.identifier = PAGE_IDENTIFIER; // Replace PAGE_IDENTIFIER with your page's unique identifier variable
      };
      */
      (function() { // DON'T EDIT BELOW THIS LINE
        var d = document,
          s = d.createElement('script');
        /*写入自己的disqus信息*/
        s.src = '{{ site.disqus_url }}';
        s.setAttribute('data-timestamp', +new Date());
        (d.head || d.body).appendChild(s);
      })();

    </script>

{% endif %}

{% if site.livere %}
    <section class="post-footer-item comment">
      <div id="lv-container" data-id="city" data-uid="{{ site.livere_uid }}"></div>
    </section>

    <!-- 来必力City版安装代码 -->
    <script type="text/javascript">
       (function(d, s) {
           var j, e = d.getElementsByTagName(s)[0];

           if (typeof LivereTower === 'function') { return; }

           j = d.createElement(s);
           j.src = 'https://cdn-city.livere.com/js/embed.dist.js';
           j.async = true;

           e.parentNode.insertBefore(j, e);
       })(document, 'script');
    </script>
    <noscript>为正常使用来必力评论功能请激活JavaScript</noscript>
    <!-- City版安装代码已完成 -->

{% endif %}

{% if site.Gitment %}
<section class="post-footer-item comment">
  <div id="container"></div>
</section>

<link rel="stylesheet" href="https://imsun.github.io/gitment/style/default.css">
<script src="https://imsun.github.io/gitment/dist/gitment.browser.js"></script>
<script>
var gitment = new Gitment({
  id: '{{ page.id }}', // 可选。默认为 location.href
  owner: '{{ site.Gitment_owner }}',
  repo: '{{ site.Gitment_repo }}',
  oauth: {
    client_id: '{{ site.client_id }}',
    client_secret: '{{ site.client_secret }}',
  },
})
gitment.render('container')
</script>
{% endif %}
